Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[WIP] [CI:DOCS] GHA: Add staticcheck workflow #4892

Closed
wants to merge 1 commit into from

Conversation

cevich
Copy link
Member

@cevich cevich commented Jun 28, 2023

What type of PR is this?

/kind other

What this PR does / why we need it:

Ref:

This is NOT the same thing as the golangci-lint staticcheck. It checks other items not covered by golangci-lint, such as multiple (redundant) package imports).

How to verify it

The new github-actions workflow will pass.

Which issue(s) this PR fixes:

None

Special notes for your reviewer:

Does this PR introduce a user-facing change?

None

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jun 28, 2023

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: cevich

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@cevich cevich force-pushed the add_staticcheck branch 9 times, most recently from 9d17eea to f9dbe0c Compare June 28, 2023 16:28
Ref:
  * containers#4880
  * containers#4884

This is ***NOT*** the same thing as the golangci-lint staticcheck.  It
checks other items not covered by golangci-lint, such as multiple
(redundant) package imports).

Signed-off-by: Chris Evich <cevich@redhat.com>
@cevich
Copy link
Member Author

cevich commented Jun 28, 2023

Ugh 😞 the staticcheck tool likely needs to run under Cirrus-CI in one/more of our managed CI VM images. Apparently it needs to build the project, which requires a special environment. I'm loath to manage/maintain multiple CI environments, and what we have running in Cirrus-CI is even more battle-hardened that github-actions.

@edsantiago edsantiago changed the title [WIP] [CI:DOCS] GHA: Add staticchck workflow [WIP] [CI:DOCS] GHA: Add staticcheck workflow Jun 28, 2023
@cevich
Copy link
Member Author

cevich commented Jun 29, 2023

More reason to not do this in CI: https://staticcheck.dev/docs/running-staticcheck/cli/build-tags/

I'll likely still bring the tool into the CI VM images, on the off-chance somebody wants to use it from the CI container images, or hack/get_ci_vm.sh.

@cevich cevich closed this Jun 29, 2023
@edsantiago
Copy link
Member

I would suggest not bringing it into the CI VM images. Instead, if someone needs it, they can vendor it into tests?/tools.

@cevich
Copy link
Member Author

cevich commented Jun 29, 2023

K. Thanks for the suggestion.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 28, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants